package com.zhilianbao.leyaogo.http.api;

import android.content.Context;

import com.zhilianbao.leyaogo.constants.HttpConfig;
import com.zhilianbao.leyaogo.http.client.LeYaoGoClient;
import com.zhilianbao.okhttputils.callback.Callback;
import com.zhilianbao.okhttputils.model.JsonParams;

/**
 * Author: hcy
 * Description:
 * Created: 2016/11/29 16:30
 */
public class CouponApi {

    /**
     * 可用优惠券
     */
    public static final String METHOD_CAN_USE_COUPON = "coupons/getMyCanUseCouponsList";


    public static void getCanUseCouponList(Context context, String goodsId, String goodsSkuId, String number, long userId, double amountPrice ,Callback callback){
        JsonParams jsonParams = new JsonParams();
        jsonParams.put("goodsId", goodsId);
        jsonParams.put("goodsSkuId", goodsSkuId);
        jsonParams.put("number", number);
        jsonParams.put("userId", userId);
        jsonParams.put("amountPrice", amountPrice);
        LeYaoGoClient.post(context, HttpConfig.BASE_URL + METHOD_CAN_USE_COUPON, jsonParams, callback);
    }
}
